/**
 * Copyright &copy; 2012-2017 <a href="https://vivo.com">vivo</a> All rights reserved.
 */
package com.vivo.employee.entity;

import com.thinkgem.jeesite.modules.sys.entity.Office;
import org.hibernate.validator.constraints.Length;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import javax.validation.constraints.NotNull;
import com.thinkgem.jeesite.common.utils.excel.annotation.ExcelField;

import com.thinkgem.jeesite.common.persistence.DataEntity;

/**
 * 离职管理Entity
 * @author jyangye
 * @version 2017-12-28
 */
public class ViEmpOutdutyManager extends DataEntity<ViEmpOutdutyManager> {
	
	private static final long serialVersionUID = 1L;
	private String employeeId;		// 员工信息
	private String name;		// 员工姓名
	private String code;		// 员工编号
	private Date preOutdutyDate;		// 预计离职日期
	private String outdutyReason;		// 离职原因
	private String isActive;		// 是否生效
	private Date beginPreOutdutyDate;		// 开始 预计离职日期
	private Date endPreOutdutyDate;		// 结束 预计离职日期

    private Office comp;
    private Office dept;
    private Office post;

    private Date outdutyDate; // 实际离职日期
	
	public ViEmpOutdutyManager() {
		super();
	}

	public ViEmpOutdutyManager(String id){
		super(id);
	}


	public String getEmployeeId() {
		return employeeId;
	}

	public void setEmployeeId(String employeeId) {
		this.employeeId = employeeId;
	}
	
	@Length(min=1, max=32, message="员工姓名长度必须介于 1 和 32 之间")
	@ExcelField(title="姓名", align=2, sort=10)
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}
	
	@Length(min=1, max=32, message="员工编号长度必须介于 1 和 32 之间")
	@ExcelField(title="*身份证号", align=2, sort=20, isText = true)
	public String getCode() {
		return code;
	}

	public void setCode(String code) {
		this.code = code;
	}


    public Office getComp() {
        return comp;
    }

    public void setComp(Office comp) {
        this.comp = comp;
    }

    @ExcelField(title="部门", align=2, sort=30)
    public Office getDept() {
        return dept;
    }

    public void setDept(Office dept) {
        this.dept = dept;
    }

    @ExcelField(title="岗位", align=2, sort=40)
    public Office getPost() {
        return post;
    }

    public void setPost(Office post) {
        this.post = post;
    }

	
	@JsonFormat(pattern = "yyyy-MM-dd")
	@NotNull(message="离职日期不能为空")
	@ExcelField(title="*离职日期", align=2, sort=50)
	public Date getPreOutdutyDate() {
		return preOutdutyDate;
	}

	public void setPreOutdutyDate(Date preOutdutyDate) {
		this.preOutdutyDate = preOutdutyDate;
	}
	
	@Length(min=0, max=64, message="离职原因长度必须介于 0 和 64 之间")
	@ExcelField(title="*离职原因", align=2, sort=60)
	public String getOutdutyReason() {
		return outdutyReason;
	}

	public void setOutdutyReason(String outdutyReason) {
		this.outdutyReason = outdutyReason;
	}
	

	public String getIsActive() {
		return isActive;
	}

	public void setIsActive(String isActive) {
		this.isActive = isActive;
	}
	
	public Date getBeginPreOutdutyDate() {
		return beginPreOutdutyDate;
	}

	public void setBeginPreOutdutyDate(Date beginPreOutdutyDate) {
		this.beginPreOutdutyDate = beginPreOutdutyDate;
	}
	
	public Date getEndPreOutdutyDate() {
		return endPreOutdutyDate;
	}

	public void setEndPreOutdutyDate(Date endPreOutdutyDate) {
		this.endPreOutdutyDate = endPreOutdutyDate;
	}


    public Date getOutdutyDate() {
        return outdutyDate;
    }

    public void setOutdutyDate(Date outdutyDate) {
        this.outdutyDate = outdutyDate;
    }
}